<template>
	<svg class="svg-icon" aria-hidden="true">
		<use :href="symbolId" />
	</svg>
</template>
<script lang="ts" setup>
import { computed } from "vue";

const props = defineProps({
	prefix: {
		type: String,
		default: "icon"
	},
	name: {
		type: String,
		required: true
	}
});

const symbolId = computed(() => `#${props.prefix}-${props.name}`);
</script>
<style lang="scss" scoped>
.svg-icon {
	width: 1em;
	height: 1em;
	overflow: hidden;
	fill: currentColor;
}
</style>
